let i = 0
function calcNumber() {
  postMessage(i)
  i++
  setTimeout('calcNumber()', 1000)
}
calcNumber()
